package com.nulldev.util.java.swing.font;

import java.awt.Color;
import java.awt.Component;
import java.awt.Font;

public class SWTItem {
	private final Component item;
	private final Font font;
	private final Color foreground, background;

	public SWTItem(final Component item) {
		this.item = item;
		this.font = item.getFont();
		this.foreground = item.getForeground();
		this.background = item.getBackground();
	}

	public Component item() {
		return this.item;
	}
	
	public void setFont(final Font font) {
		this.item.setFont(font);
	}
	
	public Color foreground() {
		return this.foreground;
	}
	
	public Color background() {
		return this.background;
	}

	public Font font() {
		return this.font;
	}
}
